//-----------------------------------------------------------------------------
// ETH.H
//
//-----------------------------------------------------------------------------
void Rtl8019AS_Init(void);
void Rtl8019AS_WriteNodeID(void);
void query_frame(void);
void rcve_frame(UCHAR xdata * outbuf, UINT *);
void send_frame(UCHAR xdata *, UINT);
void Rtl8019AS_Reset(); 
// Port addresses	for Cirrus CS8900A Ethernet controller
#define PORT_RXTX_DATA     0
#define PORT_TX_CMD        2
#define PORT_TX_LENGTH     3
#define PORT_ISQ           4
#define PORT_PKTPG_PTR     5
#define PORT_PKTPG_DATA    6


// PacketPage addresses	for Cirrus CS8900A Ethernet controller
#define PKTPG_EISA_NUM     0x0000
#define PKTPG_PRODUCT_ID   0x0002
#define PKTPG_IO_BASE      0x0020
#define PKTPG_INT_NUM      0x0022
#define PKTPG_MEM_BASE     0x002C
#define PKTPG_EEPROM_CMD   0x0040
#define PKTPG_EEPROM_DATA  0x0042
#define PKTPG_RX_CFG       0x0102
#define PKTPG_RX_CTL       0x0104
#define PKTPG_TX_CFG       0x0106
#define PKTPG_BUF_CFG      0x010A
#define PKTPG_LINE_CTL     0x0112
#define PKTPG_SELF_CTL     0x0114
#define PKTPG_BUS_CTL      0x0116
#define PKTPG_TEST_CTL     0x0118
#define PKTPG_ISQ          0x0120
#define PKTPG_RX_EVENT     0x0124
#define PKTPG_TX_EVENT     0x0128
#define PKTPG_BUF_EVENT    0x012C
#define PKTPG_RX_MISS      0x0130
#define PKTPG_TX_COL       0x0132
#define PKTPG_LINE_ST      0x0134
#define PKTPG_SELF_ST      0x0136
#define PKTPG_BUS_ST       0x0138
#define PKTPG_TX_CMD       0x0144
#define PKTPG_TX_LENGTH    0x0146
#define PKTPG_IND_ADDR     0x0158
#define PKTPG_RX_STATUS    0x0400
#define PKTPG_RX_LENGTH    0x0402
#define PKTPG_RX_FRAME     0x0404
#define PKTPG_TX_FRAME     0x0A00


void eth_rcve(UCHAR xdata *);
void eth_send(UCHAR xdata *, UCHAR *, UINT, UINT);
